package com.koron.order.common.bean.base;

import lombok.Data;

import java.util.ArrayList;
import java.util.List;

/**
 * @ClassName OrderStatus
 * @description
 * @Author zhouj
 * @Date 2022/2/25 15:18
 */
@Data
public class OrderStatus {

    //待派工
    public static String WAIT_DISPATCH = "WAIT_DISPATCH";

    //待执行
    public static String WAIT_EXECUTE = "WAIT_EXECUTE";

    //执行中
    public static String IN_EXECUTE = "IN_EXECUTE";

    //待验收
    public static String WAIT_ACCEPT = "WAIT_ACCEPT";

    //待审核
    public static String WAIT_REVIEW = "WAIT_REVIEW";

    //已归档
    public static String ARCHIVED = "ARCHIVED";

    //待巡视
    public static String WAIT_PATROL = "WAIT_PATROL";

    //巡视中
    public static String IN_PATROL = "IN_PATROL";

    //编制大修报告
    public static String PREPARE_REPORT = "PREPARE_REPORT";

    //已巡视
    public static String END_PATROL = "END_PATROL";

    public static List<String> unDoneList = new ArrayList<String>() {
        {
            add(WAIT_DISPATCH);
            add(WAIT_EXECUTE);
            add(IN_EXECUTE);
            add(WAIT_PATROL);
            add(IN_PATROL);
            add(PREPARE_REPORT);
        }
    };

    public static List<String> doneList = new ArrayList<String>() {
        {
            add(ARCHIVED);
            add(END_PATROL);
        }
    };

    public static List<String> waitAcceptList = new ArrayList<String>() {
        {
            add(WAIT_ACCEPT);
            add(WAIT_REVIEW);
        }
    };

    public final static List<String> allList = new ArrayList<String>() {
        {

            addAll(unDoneList);
            addAll(doneList);
            addAll(waitAcceptList);

        }
    };

    public static Boolean isDoneList(String str) {
        return doneList.contains(str);
    }

    public static Boolean isUnDoneList(String str) {
        return unDoneList.contains(str);
    }

}
